<?php
namespace app\api\controller;
use app\common\controller\Api;
use app\admin\model\Certificate as CertificateModel;
class Certificate extends Api{
    protected $noNeedRight = '*';

    public function _initialize()
    {
        parent::_initialize();
    }
    //证书列表
    public function list(){
        $certificateList = CertificateModel::where("user_id", $this->auth->getUser()->id)->select();
        $imgList = [];
        foreach ($certificateList as $c){
            $tmp = explode(",", $c->file_images);
            $imgList = array_merge($imgList, $tmp);
        }
        $this->success("success", $imgList);
    }
}
